package org.example.mq.brokerserver.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.example.mq.brokerserver.core.Binding;
import org.example.mq.brokerserver.core.Exchange;
import org.example.mq.brokerserver.core.ExchangeType;
import org.example.mq.brokerserver.core.MQqueue;

import java.beans.BeanInfo;
import java.util.List;

@Mapper
public interface MetaMapper {
    void createExchangeTable();
    void createMQqueueTable();
    void createBindingTable();
    //插入和删除
    void insertExchange(Exchange exchange);
    void insertQueue(MQqueue mQqueue);
    int insertBinding(Binding binding);
    void deleteExchange(String name);
    void deleteQueue(String name);
    void deleteBinding(Binding binding);
    List<Exchange> selectAllExchange();
    List<MQqueue> selectAllMQqueue();
    List<Binding> selectAllBinding();
}
